package its_models.tutor_model;

import its_models.expert_model.expert_help_util.StrategyGraphUnit;
import its_models.expert_model.expert_help_util.StepsMatrix;
import java.util.ArrayList;
import model_controller.ControlLayer;

public class TutorModel {
    /* Constructor */
    public TutorModel(ControlLayer inputController){
        Controller = inputController;
        hintsGenerator = new HintsGenerator(Controller);
    }

    /* HintsGenerator */
    /* Settings */
    public void setupHintsGenerator(StrategyGraphUnit[][] inputSolvedPuzzle){
        hintsGenerator.setup(inputSolvedPuzzle);
    }
    // 20091019 phrase2 start
    public void setupStepsMatrix(StepsMatrix inputStepsMatrix){
        hintsGenerator.setupStepsMatrix(inputStepsMatrix);
    }
    // 20091019 phrase2 end

    // 20091018 phrase2 start
    public String getAllLogicalRule(int indexX, int indexY){
        return hintsGenerator.getAllLogicalRule(indexX, indexY);
    }
    // 20091018 phrase2 end

    public void setRulesRanking(ArrayList<Integer> inputRulesRanking){
        hintsGenerator.setRulesRanking(inputRulesRanking);
    }
    /* get Hints*/
    public boolean isLearnerInputCorrect(int inputIndexX, int inputIndexY, int inputCellValue){
        return hintsGenerator.isLearnerInputCorrect(inputIndexX, inputIndexY, inputCellValue);
    }
    public boolean isLearnerInputAllCorrect(){
        return hintsGenerator.isLearnerInputAllCorrect();
    }

    public String getHints(int inputHintsLevel){
       return hintsGenerator.getHints(inputHintsLevel);
    }
    // 20091112 phrase2 start
    public void reStartAutoHintsTimer(int inputHintsLevel){
        hintsGenerator.reStartAutoHintsTimer(inputHintsLevel);
    }
    public void isEnableAutoHints(boolean isEnabled){
        hintsGenerator.isEnableAutoHints(isEnabled);
    }
    public void setAutoHintsTimerOff(){
        hintsGenerator.setAutoHintsTimerOff();
    }
    // 20091112 phrase2 end

     public boolean isElminHintsCell(StrategyGraphUnit checkUnit){
         return hintsGenerator.isElminHintsCell(checkUnit);
     }

     public StrategyGraphUnit getElminHintsCell(StrategyGraphUnit checkUnit){
         return hintsGenerator.getElminHintsCell(checkUnit);
     }

   // 20100126
    public ArrayList<Integer> getRulesRanking(){
        return hintsGenerator.getRulesRanking();
    }


    /* local variables */
    private ControlLayer Controller;
    private HintsGenerator hintsGenerator;


}
